<template>
  <div>
    <el-button @click="closeDrawer()" size="small" type="primary">导入模板下载</el-button>
    <div style="margin:20px 0"></div>
    <importFile
      :title="'导入'"
      :actionUrl="urls"
      @close="closeHandler"
    />
    <div style="height:47px;"></div>
    <div
      :style="{
        position: 'absolute',
        left: 0,
        bottom: 0,
        right: 0,
        zIndex: 9,
        borderTop: '1px solid #e9e9e9',
        padding: '10px 20px',
        background: '#fff',
        textAlign: 'right'
      }"
    >

    </div>
  </div>
</template>
<script>
import {excelList} from '@/api/omSale/HeadquartersInventory/VehicleTransfer/index.js'
import moment from 'moment';
import {downloadUrl} from '@/utils'
export default {
  data(){
    return{
      urls:'/api/cmscloud.retail/dlrProductGroup/upload',
      initialValue:[],
      fetchParams:{

      },
      fetchApi:()=>{},
    }
  },
  created(){
  },
  methods:{
    closeDrawer(type){
      this.$confirm('是否将Excel表格保存至本地文件夹?', '提示', {
          confirmButtonText: '下载',
          cancelButtonText: '取消',
          type: 'warning'
        }).then(() => {

          downloadUrl('https://bjev-cms-oss-public.oss-cn-beijing.aliyuncs.com/1.1.8-经销商批售车型授权（OEM）-导入模版 .xlsx','批售车型授权');

        }).catch(() => {
          this.$message({
            type: 'info',
            message: '已取消'
          });
        });
    },
    closeHandler(val){
      this.$emit('close')
    },
    successHandler(val){
      console.log(val,'val')
    },
    selectChangeHandle(val){

    }
  },
}

</script>
